{{!
  Copyright (c) HashiCorp, Inc.
  SPDX-License-Identifier: BUSL-1.1
~}}

<Hds::Card::Container
  @level="mid"
  @hasBorder={{true}}
  class="overview-card"
  data-test-overview-card-container={{@cardTitle}}
  ...attributes
>
  <div class="flex row-wrap space-between has-bottom-margin-m" data-test-overview-card={{@cardTitle}}>
    <h3 class="has-text-weight-bold is-size-5">{{@cardTitle}}</h3>
    {{#if @actionText}}
      <Hds::Link::Standalone
        @icon={{or @actionIcon "chevron-right"}}
        @iconPosition="trailing"
        @text={{@actionText}}
        @route={{@actionTo}}
        @isRouteExternal={{@actionExternal}}
        @query={{@actionQuery}}
        data-test-action-text={{@actionText}}
      />
    {{/if}}
  </div>
  <p class="has-text-grey is-size-8 {{unless @actionText 'has-top-margin-s'}}">{{@subText}}</p>
  {{yield}}
</Hds::Card::Container>